<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
        // 整形 : integer  浮点数 float
        let score = '413.46416';
        
        // 1.字符串转化为 nunber
        //  score = parseInt(score);
        score = parseFloat(score);
        console.log(score);
        console.log(typeof score);

        // 2.not a number
        score = parseInt('也穿过人山人海');
        console.log(score);

        // 3.强制转化为 number
        let age = Number('就这么走');
        console.log(typeof age);
    </script>
</body>
</html>